package www.wen.com.common.lib.data.entities


import android.os.Parcelable
import androidx.annotation.Keep
import kotlinx.parcelize.Parcelize

@Keep
data class ServerSelfListEntity(
        val content: List<Content>,
        val empty: Boolean, // false
        val first: Boolean, // true
        val last: Boolean, // true
        val number: Int, // 0
        val numberOfElements: Int, // 8
        val pageable: Pageable,
        val size: Int, // 20
        val sort: Sort,
        val totalElements: Int, // 8
        val totalPages: Int // 1
) {
    @Keep
    @Parcelize
    data class Content(
        val createTime: String, // 2021-09-15T11:17:55.000+0800
        val forbidReason: String,
        val officialFlag: String, // n
        val recommendFlag: String, // n
        val serverBackground: String,
        var serverId: String, // T88966364
        var serverLogo: String, // T65562628/202109/20210915111754_165785.png
        var serverName: String, // 缘
        val serverStatus: Int, // 0
        val ownUserId: String, // 0
        val unForbidTime: String?,
        val teamIds: List<String>?,
        val serverMember: ServerMember?,

        var serverGroups:List<ServerEntity.ServerGroup>?,
        var isSelected:Boolean,
        var unreadCount:Int
    ):Parcelable

    @Keep
    @Parcelize
    data class ServerMember(
        var allowFriendFlag: String,
        val avatar: String,
        val createTime: String,
        val id: Int, // 0
        var nickName: String,
        var noticeType: String,
        val ownerFlag: String,
        val serverId: String,
        val updateTime: String,
        val userId: String
    ):Parcelable

    @Keep
    data class Pageable(
        val offset: Int, // 0
        val pageNumber: Int, // 0
        val pageSize: Int, // 20
        val paged: Boolean, // true
        val sort: Sort,
        val unpaged: Boolean // false
    ) {
        @Keep
        data class Sort(
            val empty: Boolean, // true
            val sorted: Boolean, // false
            val unsorted: Boolean // true
        )
    }

    @Keep
    data class Sort(
        val empty: Boolean, // true
        val sorted: Boolean, // false
        val unsorted: Boolean // true
    )
}